const network = {
  getNetworkType: () => {
    return new Promise((resolve, reject) => {
      wx.getNetworkType({
        success: (res) => {
          resolve(res.networkType)
        }
      })
    })
  }
}

module.exports = network
  